/* SPDX-License-Identifier: GPL-2.0 */
/*
 * lombo_thermal.h - Generic definitions for LomboTech thermal
 *
 * Copyright (C) 2016-2018, LomboTech Co.Ltd.
 * Author: lomboswer <lomboswer@lombotech.com>
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 */
#ifndef _LOMBO_THERMAL_H_
#define _LOMBO_THERMAL_H_

#include <linux/thermal.h>
#include <mach/common.h>

#define MAX_TSENSOR_NUM	8

/* struct lombo_sensor_data - the private data of temperature sensor */
struct lombo_sensor_data {
	struct thermal_zone_device *tzd;
	int sensor_id;
	int slope;
	int offset;
	int crit_mode;
};

/**
 * struct lombo_thermal_data - the private data of thermal driver
 * @pdev: platform device of thermal
 */
struct lombo_thermal_data {
	struct platform_device *pdev;
	struct mutex th_lock;
	enum thermal_device_mode mode;
	struct lombo_sensor_data sensor_data[MAX_TSENSOR_NUM];
	int sensor_num;
};

#include <mach/debug.h>

 /* redefine mode name, for PTR_XXX */
#undef MOD_NAME
#define MOD_NAME "THM"

#endif /* __LOMBO_THERMAL_H__ */

